package com.zjyd.douyanglive.controller;

import com.zjyd.douyanglive.service.ILiveService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 直播接口
 */
@Slf4j
@RestController
@RequestMapping("/douyang/live")
public class LiveController {

    @Autowired
    private ILiveService iLiveService;

    /**
     * 获取直播间列表
     * @return
     */
    @GetMapping("/getLiveList")
    public String getLiveList(){
        return "这是一个直播列表";
    }

    /**
     * 直播打赏接口
     * @return
     */
    @GetMapping("/liveTip")
    public String liveTip(){
        log.info("1、请求的进入");
        String s = iLiveService.liveTip(101);
        return s;
    }
}
